package com.properties;

import lombok.Getter;
import lombok.Setter;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;
import org.springframework.stereotype.Component;

import java.util.List;

/**
 * @author SayYi
 */
@Component
@ConfigurationProperties(prefix = WebProperties.PREFIX)
@Getter
@Setter
public class WebProperties {

    public static final String PREFIX = "web";

    /**
     * 白名单
     */
    private List<String> whitelist;

    /**
     * 允许访问白名单的ip
     */
    private List<String> ipWhitelist;

    /**
     * 需要进行ip限制的路由
     */
    private List<String> ipWhitelistUrl;
}
